//
//  InfoType.h
//  Trading365
//
//  Created by yifei tong on 12-2-7.
//  Copyright (c) 2012年 dhc. All rights reserved.
//

#import <Foundation/Foundation.h>


#define INFO_TYPE_PRODUCT   1   //产品
#define INFO_TYPE_PRODUCT_CATEGORY  11//产品类别
#define INFO_TYPE_PRODUCT_UNIT  12//@"单位",
#define INFO_TYPE_PRODUCT_CUSTOM_CODE  13//@"海关编码",
#define INFO_TYPE_PRODUCT_ADD   14   //add产品

#define INFO_TYPE_CUSTOMER  2   //客户
#define INFO_TYPE_CUSTOMER_CONTACT_ADD   21   //add联系人
#define INFO_TYPE_CUSTOMER_TYPE    22 //"客户类型，
#define INFO_TYPE_CUSTOMER_ORIGIN    23 //3客户来源
#define INFO_TYPE_CUSTOMER_CREADIT    24 //4信用等级，

#define INFO_TYPE_CHANCE    3   //商机
#define INFO_TYPE_CHANCE_ADD   21   //add联系人

#define INFO_TYPE_QUOTATION 4   //报价
#define INFO_TYPE_QUOTATION_ADD   41   //add

#define INFO_TYPE_EMPLOYE  101   //业务员


#define INFO_TYPE_CURRENCY_TYPE   102   //currency_type
#define INFO_TYPE_PRICE_TERMS   103   //PRICE_TERMS
#define INFO_TYPE_DEPARTURE_PORT  104   //DEPARTURE_PORT
#define INFO_TYPE_ARRIVAL_PORT   105   //ARRIVAL_PORT
#define INFO_TYPE_CONTACT   106   //
#define INFO_TYPE_COST_MODEL    107   //cost_model
#define INFO_TYPE_QUOT_PROD_UNIT   108


#define INFO_TYPE_QUOT_TAB0    0  //报价界面的tab
#define INFO_TYPE_QUOT_TAB1    1
#define INFO_TYPE_QUOT_TAB2    2
#define INFO_TYPE_QUOT_TAB3    3

//显示该页面是否需要刷新view
#define INFO_TYPE_VIEW_NOFRESH    0
#define INFO_TYPE_VIEW_REFRESH    1

//手动或自动登陆
#define INFO_TYPE_LOGIN_BLANK    0
#define INFO_TYPE_LOGIN_AUTO    1
#define INFO_TYPE_LOGIN_MANU    2

//////常量字符串定义
#define INFO_STRING_CUSTOMER @"客户"
#define INFO_STRING_CUSTOMER_CONTACT_ADD @"添加联系人"
#define INFO_STRING_CUSTOMER_CONTACT_LIST @"联系人列表"
#define INFO_STRING_CUSTOMER_PICTURE_LIST @"客户图片"
#define INFO_STRING_CUSTOMER_ADD @"新增客户"
#define INFO_STRING_CUSTOMER_TYPE  @"客户类型"
#define INFO_STRING_CUSTOMER_ORIGIN  @"客户来源"
#define INFO_STRING_CUSTOMER_CREADIT  @"信用等级"

#define INFO_STRING_PRODUCT @"产品"
#define INFO_STRING_PRODUCT_PICTURE_LIST @"产品图片"
#define INFO_STRING_PRODUCT_PICTURE_ADD @"添加产品图片"
#define INFO_STRING_PRODUCT_ADD @"新增产品"
#define INFO_STRING_PRODUCT_CATEGORY @"产品类别"
#define INFO_STRING_PRODUCT_UNIT @"单位"
#define INFO_STRING_PRODUCT_CUSTOM_CODE @"海关编码"



#define INFO_STRING_QUOTATION @"报价"
#define INFO_STRING_QUOTATION_ADD @"添加报价"

#define INFO_STRING_CHANCE @"商机"
#define INFO_STRING_CHANCE_ADD @"添加商机"

#define INFO_STRING_CURRENCY @"币种"
#define INFO_STRING_EMPLOYE @"业务员"
#define INFO_STRING_CONTACT @"联系人"
#define INFO_STRING_PRICE_TERMS @"价格条款"
#define INFO_STRING_DEPARTURE_PORT @"起运港"
#define INFO_STRING_ARRIVAL_PORT @"目的港"
#define INFO_STRING_COST_MODEL @"成本模型"
#define INFO_STRING_QUOT_PROD_UNIT @"产品单位"

//Mission
#define INFO_STRING_MISSION @"待办"
#define INFO_STRING_MISSION_TYPE1 @"系统消息"
#define INFO_STRING_MISSION_TYPE2 @"审批消息"
#define INFO_STRING_MISSION_TYPE3 @"日程消息"
#define INFO_STRING_MISSION_TYPE4 @"任务消息"

#define INFO_STRING_MISSION_TYPE5 @"待批事项"

#define INFO_STRING_MISSION_SECTION_TYPE1 @"待批事项"
#define INFO_STRING_MISSION_SECTION_TYPE2 @"消息中心"

#define INFO_STRING_APPROVE_AGREE0 @"驳回"
#define INFO_STRING_APPROVE_AGREE1 @"同意"
#define INFO_STRING_APPROVE_AGREE3 @"提交审批"

//Text for Product
#define INFO_NAME_PRODUCT_NAME @"PRODUCT_NAME"
#define INFO_NAME_PRODUCT_CATEGORY @"PRODUCT_CATEGORY"
#define INFO_NAME_PRODUCT_CATEGORY_ID @"PRODUCT_CATEGORY_ID"
#define INFO_NAME_PRODUCT_UNIT @"PRODUCT_UNIT"
#define INFO_NAME_PRODUCT_UNIT_ID @"PRODUCT_UNIT_ID"
#define INFO_NAME_PRODUCT_CUSTOM_CODE @"PRODUCT_CUSTOM_CODE"
#define INFO_NAME_PRODUCT_CUSTOM_CODE_ID @"PRODUCT_CUSTOM_CODE_ID"

//Text for CustomerContact
#define INFO_NAME_CUSTOMER_CONTACT_NAME @"CUSTOMER_CONTACT_NAME"
#define INFO_NAME_CUSTOMER_CONTACT_TEL @"CUSTOMER_CONTACT_TEL"
#define INFO_NAME_CUSTOMER_CONTACT_MAIL @"CUSTOMER_CONTACT_MAIL"
#define INFO_NAME_CUSTOMER_CONTACT_REMARKS @"CUSTOMER_CONTACT_REMARK"

//Text for Add Quotation
//custoer
#define INFO_NAME_QUOTATION_CUSTOMER_NAME @"QUOTATION_CUSTOMER_NAME"
#define INFO_NAME_QUOTATION_CUSTOMER_NAME_ID @"QUOTATION_CUSTOMER_NAME_ID"
//chance
#define INFO_NAME_QUOTATION_CHANCE_NAME @"QUOTATION_CHANCE_NAME"
#define INFO_NAME_QUOTATION_CHANCE_NAME_ID @"QUOTATION_CHANCE_NAME_ID"
//contact
#define INFO_NAME_QUOTATION_CONTACT_NAME @"QUOTATION_CONTACT_NAME"
#define INFO_NAME_QUOTATION_CONTACT_NAME_ID @"QUOTATION_CONTACT_NAME_ID"
//currency_type
#define INFO_NAME_QUOTATION_CURRENCY_TYPE @"QUOTATION_CURRENCY_TYPE"
#define INFO_NAME_QUOTATION_CURRENCY_TYPE_ID @"QUOTATION_CURRENCY_TYPE_ID"
//price_terms
#define INFO_NAME_QUOTATION_PRICE_TERMS @"QUOTATION_PRICE_TERMS"
#define INFO_NAME_QUOTATION_PRICE_TERMS_ID @"QUOTATION_PRICE_TERMS_ID"
//departure_port
#define INFO_NAME_QUOTATION_DEPARTURE_PORT @"QUOTATION_DEPARTURE_PORT"
#define INFO_NAME_QUOTATION_DEPARTURE_PORT_ID @"QUOTATION_DEPARTURE_PORT_ID"
//arrival_port
#define INFO_NAME_QUOTATION_ARRIVAL_PORT @"QUOTATION_ARRIVAL_PORT"
#define INFO_NAME_QUOTATION_ARRIVAL_PORT_ID @"QUOTATION_ARRIVAL_PORT_ID"
//TEL
#define INFO_NAME_QUOTATION_TEL @"QUOTATION_TEL"
//报价日期
#define INFO_NAME_QUOTATION_QUOTE_DATE @"QUOTATION_QUOTE_DATE"
//截止日期quote_validity_date
#define INFO_NAME_QUOTATION_QUOTE_VALIDITY_DATE @"QUOTATION_QUOTE_VALIDITY_DATE"

//Chance
#define INFO_NAME_CHANCE_NAME @"CHANCE_NAME"
#define INFO_NAME_CHANCE_CUSTOMER_NAME @"CHANCE_CUSTOMER_NAME"
#define INFO_NAME_CHANCE_CUSTOMER_NAME_ID @"CHANCE_CUSTOMER_NAME_ID"
#define INFO_NAME_CHANCE_EMPLOYE_NAME @"CHANCE_EMPLOYE_NAME"
#define INFO_NAME_CHANCE_EMPLOYE_NAME_ID @"CHANCE_EMPLOYE_NAME_ID"

//static CGFloat theKeyboardHeight = 216.0f;

@interface InfoType : NSObject
{
    NSMutableDictionary *tranValueDict;//界面传递值使用
    int flagInfoType;
    int flagFreshView;
}

+ (InfoType *) share;
- (InfoType *) init;

-(void)SetFlagInfoType:(int)flag;
-(int)GetFlagInfoType;

-(void)SetFlagFreshView:(int)flag;
-(int)GetFlagFreshView;

-(void)SetTranValueDict:(NSMutableDictionary *)dict;
-(NSMutableDictionary *)GetTranValueDict;

-(BOOL)IsPad;
-(BOOL)IsSimulator;

@end
